package cuiyt.designpattern.composite;

/**
 * @author cyt
 * @create 2020-07-20 13:21
 */
public class Test {

    public static void main(String[] args) {

        School school = new School("洛阳师范学院", "师范学院");

        Collage collage = new Collage("信息技术学院", "主要培养信息技术");


        school.oriOrganization.add(collage);


        Department department1 = new Department("软件工程", "软件开发");
        Department department2 = new Department("网络工程", "网络开发");

        collage.list.add(department1);
        collage.list.add(department2);


        Collage collage1 = new Collage("外国语学院", " 培养外语人才");

        collage1.list.add(new Department("商务英语", "翻译"));
        collage1.list.add(new Department("日语", " 一级"));

        school.oriOrganization.add(collage1);

        school.print();

    }
}
